#ifndef __AS_NUMBER_SCREEN__H__
#define __AS_NUMBER_SCREEN__H__

#include "ASScreen.h"
#include "..\control\ASLabel.h"

typedef enum
{
    AS_NP_7,
    AS_NP_8,
    AS_NP_9,

    AS_NP_4,
    AS_NP_5,
    AS_NP_6,

    AS_NP_0,
    AS_NP_1,
    AS_NP_2,
    AS_NP_3,


    AS_NP_00,
    AS_NP_CLEAR,
    AS_NP_DOT,
    AS_NP_PLUS,
    AS_NP_MINUS,
    AS_NP_MULTI,
    AS_NP_DEVIDE,

    AS_NP_MAX
} as_number_pad;

typedef enum
{
    AS_NO_NONE,
    AS_NO_PLUS,
    AS_NO_MINUS,
    AS_NO_MULTI,
    AS_NO_DEVIDE,

    AS_NO_MAX
} as_number_operator;


typedef struct
{
    as_screen base;

    as_label* result;
    ASINT64 r;
    ASUINT if_dot_exist;
    ASUINT frac_pos_len;
    ASINT64 operands[2];
    as_number_operator cur_op;
    ASUINT cur_operand_idx;
    ASBOOL if_first_pressed;

} as_number_screen;

void as_number_screen_init(as_screen* screen_p);
void as_number_screen_deinit(as_screen* screen_p);

void as_show_number_screen(void);
ASWCHAR* as_number_screen_get_result_str(ASUINT64 r);

#endif //__AS_NUMBER_SCREEN__H__